import {createRouter, createWebHistory, RouteRecordRaw} from 'vue-router'
import Home from '@/view/Home.vue'
import Container from '@/components/container/src/index.vue'

const routes: RouteRecordRaw[] = [
    {
        path:'/',
        component: Container,
        children:[
            {
                path: '/',
                name: 'home', 
                component: Home 
            },
            {
                path: '/chooseIcon',
                component:()=> import('@/view/chooseIcon/chooseIconView.vue')
            },
            {
                path: '/chooseArea',
                component:()=> import('@/view/chooseArea/chooseAreaView.vue')
            },
            {
                path: '/trend',
                component:()=> import('@/view/trend/trendView.vue')
            }
            ,
            {
                path: '/notification',
                component:()=> import('@/view/notification/notificationView.vue')
            }
            ,
            {
                path: '/menu',
                component:()=> import('@/view/menu/menuView.vue')
            }
            ,
            {
                path: '/time',
                component:()=> import('@/view/chooseTime/chooseTimeView.vue')
            }
            ,
            {
                path: '/progress',
                component:()=> import('@/view/progress/progressView.vue')
            }
            ,
            {
                path: '/chooseCity',
                component:()=> import('@/view/chooseCity/chooseCityView.vue')
            }
            ,
            {
                path: '/form',
                component:()=> import('@/view/form/formView.vue')
            }
            ,
            {
                path: '/modalForm',
                component:()=> import('view/modalForm/modalFormView.vue')
            }
            ,
            {
                path: '/table',
                component:()=> import('view/table/tableView.vue')
            }
        ]
    }
]


const router = createRouter({
    history: createWebHistory(),
    routes
})

export default router